<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head th:fragment="head(title)">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <!--  title内容使用传递的参数替换  -->
    <title th:replace="${title}">博客详情页</title>
    <!-- semantic ui css文件   -->
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/semantic-ui@2.4.2/dist/semantic.min.css">
    <link rel="stylesheet" href="../../static/lib/editormd/css/editormd.min.css" th:href="@{/lib/editormd/css/editormd.min.css}">
    <!-- 动态效果   -->
    <link rel="stylesheet" href="../static/css/animate.css" th:href="@{/css/animate.css}" >
    <!-- 加载表情   -->
    <link rel="stylesheet" href="../static/css/jqueryEmoji.css" th:href="@{/css/jqueryEmoji.css}">
    <!--  语法高亮 -->
    <link rel="stylesheet" href="../static/lib/prism/prism.css" th:href="@{/lib/prism/prism.css}">
    <!-- 自定义样式的css文件   -->
    <link rel="stylesheet" href="../static/css/me.css" th:href="@{/css/me.css}">
</head>
<body>
<!--导航条-->
<nav class="ui m-bg segment attached m-padded-tb-mini animated fadeInDown m-shadow-small"  th:fragment="menu(n)">
    <div class="ui container">
        <div class="ui secondary  stackable menu">
            <a href="#" class="item">
                <h1 class="ui header item m-text-thin" style="color: #ff8080">管理后台</h1>
            </a>
            <a th:href="@{/admin/blogs}" class="item m-item m-pink m-mobile-hide" th:classappend="${n==1} ? 'active':'' "><i class="icon home m-pink"></i>博客</a>
            <a th:href="@{/admin/types}" class="item m-item m-pink m-mobile-hide" th:classappend="${n==2} ? 'active':'' "><i class="idea icon m-pink"></i>分类</a>
            <a th:href="@{/admin/tags}" class="item m-item m-pink m-mobile-hide" th:classappend="${n==3} ? 'active':'' "><i class="tags icon m-pink"></i>标签</a>
            <a href="#" class="item m-item m-pink m-mobile-hide" th:classappend="${n==4} ? 'active':'' "><i class="linkify icon m-pink"></i>友链</a>
            <div class="right m-item menu m-pink m-mobile-hide" th:object="${user}">
                <div class="ui dropdown item">
                    <div class="text m-pink">
                        <img th:src="@{${session.user.avater}}" class="ui avatar image" alt="">
                        <span th:text="${session.user.nickname}"></span>
                    </div>
                    <i class="icon dropdown m-pink"></i>
                    <div class="menu m-bg">
                        <a th:href="@{/admin/logout}" class="item">注销</a>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <a href="#" class="ui big menu toggle m-pink icon button m-right-top m-mobile-show">
        <i class="sidebar icon"></i>
    </a>
</nav>
<!--script-->
<th:block th:fragment="script">
    <script src="https://cdn.jsdelivr.net/npm/jquery@3.2/dist/jquery.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/semantic-ui@2.4.2/dist/semantic.min.js"></script>
    <script src="../../static/lib/editormd/editormd.min.js" th:src="@{/lib/editormd/editormd.min.js}"></script>
</th:block>
</body>
</html>